package org.zhadoop.stream.cql.semanticanalyzer.parser.visitor;

import org.antlr.v4.runtime.misc.NotNull;
import org.zhadoop.stream.cql.semanticanalyzer.parser.CQLParser.ExpressionContext;
import org.zhadoop.stream.cql.semanticanalyzer.parser.context.OnConditionContext;

/**
 * on 条件语法遍历
 * @author zwd
 *
 */
public class OnConditionVisitor extends AbsCQLParserBaseVisitor<OnConditionContext>{

	private OnConditionContext context = null;
	
	public OnConditionVisitor() {
		context = new OnConditionContext();
	}
	@Override
	protected OnConditionContext defaultResult() {
		return context;
	}
	
	@Override
	public OnConditionContext visitExpression(@NotNull ExpressionContext ctx) {
		ExpressionVisitor visitor = new ExpressionVisitor();
        context.setExpression(visitor.visit(ctx));
        return context;
	}

}
